-- GENERATED SPELL FOR [Xabraxxis] --


function spell0_10373(pUnit, Event) --@Curse of Weakness,n/a--
pUnit:FullCastSpellOnTarget(11980,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_10373', 600, 1)
end

function spell1_10373(pUnit, Event) --@Enrage,Self--
pUnit:FullCastSpellOnTarget(8599,pUnit)
pUnit:RegisterEvent('Sorts_10373', 578, 1)
end

function spell2_10373(pUnit, Event) --@Shadow Word: Pain,n/a--
pUnit:FullCastSpellOnTarget(11639,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_10373', 18000, 1)
end

function spell3_10373(pUnit, Event) --@Xabraxxis Demon Bag,n/a--
pUnit:FullCastSpellOnTarget(19127,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_10373', 665, 1)
end

function Sorts_10373(pUnit, Event)
local choix_sorts_10373 = math.random(0, 3)
if choix_sorts_10373 == 0 then
pUnit:RegisterEvent('spell0_10373', 1, 1)
end
if choix_sorts_10373 == 1 then
pUnit:RegisterEvent('spell1_10373', 1, 1)
end
if choix_sorts_10373 == 2 then
pUnit:RegisterEvent('spell2_10373', 1, 1)
end
if choix_sorts_10373 == 3 then
pUnit:RegisterEvent('spell3_10373', 1, 1)
end
end

function mob10373_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_10373', math.random(1500, 3000), 1)
end

function mob10373_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob10373_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob10373_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(10373, 1, 'mob10373_Action')
RegisterUnitEvent(10373, 2, 'mob10373_Leave')
RegisterUnitEvent(10373, 3, 'mob10373_Kill')
RegisterUnitEvent(10373, 4, 'mob10373_Die')
